NetCloak Pro Version 3.0 Pro
User's Guide

Mail Actions

Previous | Next
Contents

What Are Mail Actions?

In addition to processing an FDML file in response to a form submission or a Web page hit, NetCloak Pro also allows you to process an FDML file whenever a message is received from any e-mail address. The collection of information needed to associate an e-mail address with an FDML file is called a "Mail Action".

NetCloak Pro can check any e-mail account located on any POP3-compatible mail server on the Internet. It can check for mail as frequently or infrequently as you like.

Using Mail Actions, you can have NetCloak Pro automatically check an e-mail address and create a new Web page, insert information into existing pages, store data, or even send another e-mail message, using the information contained in each new message. For instance, you can easily create Mail Actions to create online archives of your favorite mailing lists, automate routing of e-mail messages to the appropriate persons, or provide Web access to e-mail for members of your organization.

Setting Up Mail Actions

To create, edit, or remove Mail Actions, you use the "Mail Actions..." command in the NetCloak Pro CGI or access the "Mail Actions" link from the NetCloak Pro Web admin home page.

The Mail Action window
Figure 1: The Mail Action window

The Mail Action Web admin page
Figure 2: The Mail Action Web admin page

Because Mail Actions require NetCloak Pro to open TCP/IP connections to remote mail servers, a single control is provided to enable or disable all Mail Actions at once. To enable checking of all configured Mail Actions, check the "Enable Mail Actions" checkbox. In the CGI, checking is enabled as soon as you check the box. In the Web admin page, you must click the "Save Changes" button after checking the box. To disable Mail Actions, uncheck the box (and, in the Web admin page, click "Save Changes").

To edit an existing Mail Action, select it (in the CGI) or click the "Select" radio button for that action (in the Web admin page), then click the "Edit..." button. To create a new Mail Action, click the "New..." button. In either case, you are presented with the "Edit Mail Action" window (in the CGI) or Web admin page.

The Edit Mail Action window
Figure 3: The Edit Mail Action window

The Edit Mail Action Web admin page
Figure 4: The Edit Mail Action Web admin page

A Mail Action consists of three sets of information: which e-mail account to check, how often to check it, and what actions to take when messages are received.

Email Account Settings

To specify which e-mail account you want NetCloak Pro to check, you must provide four pieces of information: Mail Server -- Enter the IP address (such as "198.64.78.12") or domain name (such as "pop.maxum.com") of a mail server in this field. The specified IP address or domain name must be that of a machine connected to the Internet (or is at least visible to NetCloak Pro on your network), which is running a POP3 ("Post Office Protocol" version 3) mail server. That mail server must be the mail server that stores messages for the specified e-mail address.

Email Address - This field contains the fully-qualified address specification of the e-mail account from which messages will be retrieved. For instance, "chris@maxum.com". This e-mail address must be recognized as a valid address by the configured mail server.

Email Password - Enter the corresponding password for the configured e-mail account into this field. In the CGI, the password characters will appear as clear text until you tab out of the field, when they are converted to bullets. How the password field in the Web admin page is displayed depends on the particular browser you use.

Use APOP Authentication - With this box unchecked, the configured e-mail address and password are transmitted to the mail server as clear text, so that anyone "snooping" on the network will be able to read them. If the mail server supports it, using APOP authentication will encrypt the username and password during transmission, so that they cannot be easily discovered. Ask the mail server administrator if the configured mail server support APOP (or, just try it and see if it works).

Schedule Settings

NetCloak Pro will attempt to log on to the mail server using the frequency you specify here. It can be configured to check for mail as often as once per minute, or only very infrequently. Select units of "Minutes", "Hours" or "Days" from the popup menu (via the Web) or using the arrow buttons (in the CGI), and enter the number of units in the text field. For example, to check mail every 24 hours, enter "24" into the text field, and select "Hours".

You cannot select the time of day NetCloak will check mail. NetCloak Pro checks once per minute for any Mail Actions that need to run. So, if you create a Mail Action at 3:30 pm, and it is set to check mail every 24 hours, it will check that action's e-mail address at roughly 3:31 pm each day.

Action Setting

Finally, you must tell NetCloak Pro what to do when messages are received by the configured e-mail address. The way you do this is by specifying the path to an FDML file located in the configured Root Folder. In the CGI, click the "FDML File" button. You are presented with a standard MacOS "open file" dialog box. Select the FDML file you want to use to process mail messages for the configured e-mail address. In the Web admin interface, you must enter the exact path to the FDML file, from the volume name down, in the "FDML File" text field. Enter the path using MacOS file path conventions - use colons to separate folder names, and let the text field wrap the text automatically (don't insert return characters yourself).

Once you have entered all the information needed by the Mail Action, click "OK" (in the CGI) or "Save Changes" (in the Web admin page) to save the Mail Action. In the CGI, NetCloak Pro will display an error message if any fields are incorrectly filled out. No such error checking is performed in the Web admin interface, so be especially careful when editing Mail Actions this way.

Creating a Mail Action FDML File

All normal FDML directives and insertion commands are available for use in a Mail Action FDML file. Use CREATEDOC to create Web pages from mail messages; INSERTFILE to insert messages into existing pages; TEXTSTORE to maintain a tab-delimited text file of mail data; or SENDMAIL to generate messages to other e-mail addresses based on the received mail.

Where do the form field variables normally used in FDML insertion commands come from? NetCloak Pro automatically converts the header fields from each mail message into form variables that can be accessed using standard REPLACE commands. In addition, the body of each message is placed into a form field named "Body", which you can insert like this:

    <REPLACE Body>

All mail messages will contain a few standard variables that you can depend on being present when using them in REPLACE commands. These are listed below.

FromThe e-mail address of the sender of the message.
ToThe e-mail addresses of the message's primary recipients; commas separate each address. The Mail Action's configured e-mail address will be in this list.
SubjectThe "title" of the mail message.
DateThe date the message was originally transmitted, in the standard format required by the SMTP/POP3 protocols.
BodyThe body of the message (not including headers), generated by NetCloak Pro.
MailActionServerThe mail action's mail server setting.
MailActionAccountThe mail action's email address setting.
MailActionPasswordThe mail action's email password setting.
MailActionFDMLPathThe path to the mail action FDML file.
MailActionRootFolderThe root folder path used by the mail action.

In addition, most modern e-mail clients and servers will include the following optional variables in the message:

CCThe e-mail addresses of the message's secondary, "carbon-copy" recipients, separated by commas. This will only be present if secondary addresses exist.
Content-TypeDefines the format of the data contained in the e-mail message. Plain text messages have a content type of "text/plain", while HTML formatted messages have a content-type of "text/html".
Message-IDA unique identifier for the mail message used by the mail server. This unique ID is usually in the form of an email address, like <0123abc1f332@maxum.com>, so it is guaranteed to uniquely distinguish this message from all other messages on all other mail servers.

For a complete list of all the possible mail message header fields, see the RFC documents describing the format of mail messages (RFC 822) and MIME headers (RFCs 1521 and 1522), available many places on the Internet.

Message Content Types

When NetCloak Pro receives a mail message in response to a Mail Action, it looks for a "Content-Type" field and a "Content-Transfer-Encoding" field in the header of the mail message. Messages with certain content types and tranfer encodings are handled specially by NetCloak Pro.

If the content type of the message is not specified (no "Content-Type" field is present), NetCloak Pro assumes the message's content type is text.

If the content type of the message is "multipart/mixed" or "multipart/alternative", this means that the message contains either attachments or alternative ways of displaying the same message (most often, a plain text and an HTML version of the message). In this case, NetCloak will extract the "text/html" or "text/plain" part of the message, and then discard the rest. If both a "text/html" part and a "text/plain" part exist, NetCloak will use the HTML version of the message as the "Body" variable. Note that this means that NetCloak always discards attachments.

If a transfer encoding is not specified, 8-bit encoding is assumed. In other words, NetCloak does not modify the data in any way. If the tranfer encoding is either "quoted-printable" or "base64", NetCloak properly decodes the message body.


Copyright © 1996-1999 Maxum Development Corporation

http://www.maxum.com/
Previous | Next
Contents